home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
IRIX Base Documentation 1998 November
/
IRIX 6.5.2 Base Documentation November 1998.img
/
usr
/
share
/
catman
/
p_man
/
cat2
/
standard
/
sigset.z
/
sigset
Wrap
Text File
|
1998-10-20
|
8KB
|
133 lines
SSSSIIIIGGGGSSSSEEEETTTT((((2222)))) SSSSIIIIGGGGSSSSEEEETTTT((((2222))))
NNNNAAAAMMMMEEEE
sigset, sighold, sigrelse, sigignore, sigpause - signal management
(System V)
CCCC SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
####iiiinnnncccclllluuuuddddeeee <<<<ssssiiiiggggnnnnaaaallll....hhhh>>>>
_CCCC_::::
vvvvooooiiiidddd ((((****ssssiiiiggggsssseeeetttt ((((iiiinnnntttt ssssiiiigggg,,,, vvvvooooiiiidddd ((((****ddddiiiisssspppp))))(((())))))))))))(((())));;;;
_CCCC_++++_++++_::::
vvvvooooiiiidddd ((((****ssssiiiiggggsssseeeetttt ((((iiiinnnntttt ssssiiiigggg,,,, vvvvooooiiiidddd ((((****ddddiiiisssspppp))))((((iiiinnnntttt))))))))))))((((iiiinnnntttt))));;;;
_####_iiii_ffff ______XXXX_OOOO_PPPP_EEEE_NNNN______SSSS_OOOO_UUUU_RRRR_CCCC_EEEE
vvvvooooiiiidddd ((((****ssssiiiiggggsssseeeetttt ((((iiiinnnntttt ssssiiiigggg,,,, vvvvooooiiiidddd ((((****ddddiiiisssspppp))))((((iiiinnnntttt))))))))))))((((iiiinnnntttt))));;;;
_####_eeee_nnnn_dddd_iiii_ffff
iiiinnnntttt ssssiiiigggghhhhoooolllldddd ((((iiiinnnntttt ssssiiiigggg))));;;;
iiiinnnntttt ssssiiiiggggrrrreeeellllsssseeee ((((iiiinnnntttt ssssiiiigggg))));;;;
iiiinnnntttt ssssiiiiggggiiiiggggnnnnoooorrrreeee ((((iiiinnnntttt ssssiiiigggg))));;;;
iiiinnnntttt ssssiiiiggggppppaaaauuuusssseeee ((((iiiinnnntttt ssssiiiigggg))));;;;
DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
These functions provide signal management for application processes.
_ssss_iiii_gggg_ssss_eeee_tttt specifies the system signal action to be taken upon receipt of
signal _s_i_g. _d_i_s_p specifies the signal's disposition, which may be
_SSSS_IIII_GGGG______DDDD_FFFF_LLLL, _SSSS_IIII_GGGG______IIII_GGGG_NNNN, or the address of a signal handler. If _d_i_s_p is the
address of a signal handler, the system adds _s_i_g to the calling process's
signal mask before executing the signal handler; when the signal handler
returns, the system restores the calling process's signal mask to its
state prior to the delivery of the signal. In addition, if _d_i_s_p is equal
to _SSSS_IIII_GGGG______HHHH_OOOO_LLLL_DDDD, _s_i_g is added to the calling process's signal mask and the
signal's disposition remains unchanged. If _d_i_s_p is not equal to
_SSSS_IIII_GGGG______HHHH_OOOO_LLLL_DDDD, _s_i_g will be removed from the calling process's signal mask
(this behavior is different than _ssss_iiii_gggg_aaaa_cccc_tttt_iiii_oooo_nnnn(2)).
_ssss_iiii_gggg_hhhh_oooo_llll_dddd adds _s_i_g to the calling process's signal mask.
_ssss_iiii_gggg_rrrr_eeee_llll_ssss_eeee removes _s_i_g from the calling process's signal mask.
_ssss_iiii_gggg_iiii_gggg_nnnn_oooo_rrrr_eeee sets the disposition for _s_i_g to _SSSS_IIII_GGGG______IIII_GGGG_NNNN.
_ssss_iiii_gggg_pppp_aaaa_uuuu_ssss_eeee removes _s_i_g from the calling process's signal mask and suspends
the calling process until a signal is received. This system call is
useful for testing variables that are changed on the occurrence of a
signal. The correct usage is to use _ssss_iiii_gggg_hhhh_oooo_llll_dddd to block the signal first,
then test the variables. If they have not changed, then call _ssss_iiii_gggg_pppp_aaaa_uuuu_ssss_eeee to
wait for the signal.
PPPPaaaaggggeeee 1111
SSSSIIIIGGGGSSSSEEEETTTT((((2222)))) SSSSIIIIGGGGSSSSEEEETTTT((((2222))))
For a list of valid signal numbers and a general description of the
signal mechanism, please see _ssss_iiii_gggg_nnnn_aaaa_llll(5).
These functions will fail if one or more of the following are true:
[EINVAL] _s_i_g is an illegal signal number (including _SSSS_IIII_GGGG_KKKK_IIII_LLLL_LLLL and _SSSS_IIII_GGGG_SSSS_TTTT_OOOO_PPPP)
or the default handling of _s_i_g cannot be changed.
[EINVAL] The requested action is illegal (e.g. ignoring _SSSS_IIII_GGGG_CCCC_OOOO_NNNN_TTTT, which
is ignored by default).
[EINTR] A signal was caught during the system call _ssss_iiii_gggg_pppp_aaaa_uuuu_ssss_eeee.
DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
Upon successful completion, _ssss_iiii_gggg_ssss_eeee_tttt returns _SSSS_IIII_GGGG______HHHH_OOOO_LLLL_DDDD if the signal had
been blocked or the signal's previous disposition if it had not been
blocked. Otherwise, a value of SSSSIIIIGGGG____EEEERRRRRRRR is returned and _e_r_r_n_o is set to
indicate the error. SSSSIIIIGGGG____EEEERRRRRRRR is defined in <_s_y_s/_s_i_g_n_a_l._h>.
For the other functions, upon successful completion, a value of 0 is
returned. Otherwise, a value of -1 is returned and _e_r_r_n_o is set to
indicate the error.
SSSSEEEEEEEE AAAALLLLSSSSOOOO
csh(1), blockproc(2), kill(2), pause(2), setrlimit(2), sigaction(2),
signal(2), ulimit(2), wait(2), setjmp(3C), sigvec(3B), signal(5),
siginfo(5).
WWWWAAAARRRRNNNNIIIINNNNGGGGSSSS
Signals raised by the instruction stream, SSSSIIIIGGGGIIIILLLLLLLL, SSSSIIIIGGGGEEEEMMMMTTTT, SSSSIIIIGGGGBBBBUUUUSSSS, SSSSIIIIGGGGSSSSEEEEGGGGVVVV
will cause infinite loops if their handler returns, or the action is set
to SSSSIIIIGGGG____IIIIGGGGNNNN....
The POSIX signal routines (_s_i_g_a_c_t_i_o_n(2), _s_i_g_p_e_n_d_i_n_g(2), _s_i_g_p_r_o_c_m_a_s_k(2),
_s_i_g_s_u_s_p_e_n_d(2), _s_i_g_s_e_t_j_m_p(3)), and the 4.3BSD signal routines (_s_i_g_v_e_c(3B),
_s_i_g_n_a_l(3B), _s_i_g_b_l_o_c_k(3B), _s_i_g_p_a_u_s_e(3B), _s_i_g_s_e_t_m_a_s_k(3B)) must NEVER be
used with _s_i_g_n_a_l(2) or _s_i_g_s_e_t(2).
PPPPaaaaggggeeee 2222